Skip to content

Add "Common Patterns" section to Textbox docs#13248

Merged
freddyaboulton merged 2 commits intogradio-app:mainfrom
yuzegong746-cmd:docs/better-textbox-docs
Apr 13, 2026
Merged

Add "Common Patterns" section to Textbox docs#13248
freddyaboulton merged 2 commits intogradio-app:mainfrom
yuzegong746-cmd:docs/better-textbox-docs

Conversation

@yuzegong746-cmd
Copy link
Copy Markdown
Contributor

Summary

Add a "Common Patterns" section to the gr.Textbox component docs page with two practical recipes.

What's added

Multi-line text inputgr.Textbox defaults to a single line. Shows how to use lines and max_lines for longer text input such as paragraphs or code.

Password and sensitive input — Shows how to use type="password" to mask characters while passing plain text to the function.

Approach

Same pattern as #12755 (Row docs), #12922 (Image docs), and #12923 (Slider docs) — custom markdown section in the .svx file, no docstring changes.

Closes #12748

@freddyaboulton freddyaboulton added v: patch A change that requires a patch release t: fix A change that implements a fix labels Apr 13, 2026
@gradio-pr-bot
Copy link
Copy Markdown
Collaborator

gradio-pr-bot commented Apr 13, 2026

🪼 branch checks and previews

Name Status URL
Spaces ready! Spaces preview
Website ready! Website preview
Storybook ready! Storybook preview
🦄 Changes failed! Workflow log

Install Gradio from this PR

pip install https://huggingface.co/buckets/gradio/pypi-previews/resolve/1d0c706313dee90f2f0ade9bc6c5f32937526be1/gradio-6.12.0-py3-none-any.whl

Install Gradio Python Client from this PR

pip install "gradio-client @ git+https://github.com/gradio-app/gradio@1d0c706313dee90f2f0ade9bc6c5f32937526be1#subdirectory=client/python"

Install Gradio JS Client from this PR

npm install https://gradio-npm-previews.s3.amazonaws.com/1d0c706313dee90f2f0ade9bc6c5f32937526be1/gradio-client-2.2.0.tgz

Copy link
Copy Markdown
Collaborator

@freddyaboulton freddyaboulton left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thang you @yuzegong746-cmd

@freddyaboulton freddyaboulton merged commit 30264b5 into gradio-app:main Apr 13, 2026
27 of 36 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

t: fix A change that implements a fix v: patch A change that requires a patch release

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Better Textbox docs

3 participants